Private Sub Worksheet_Change(ByVal Target As Range)

    '  Create variables to hold the cell address
    '  of the data validation dropdown list,
    '  the lookup list, and the return list

    Dim dd_List As String   ' Variable for the cell that holds the Dropdown List
    Dim dd_Sheet As String  ' Variable for the sheet name that holds the lookup lists
    Dim dd_Lookup As String ' Variable for list of full names
    Dim dd_Return As String ' Variable for list of abbreviations/codes
    
'==============================================================
    
    '  Set the following range assignments to the
    '  cell address you wish to monitor and update,
    '  the lookup list, an the return list
    
    dd_List = "C10"         ' Cell that holds the Dropdown List
    dd_Sheet = "States"     ' Sheet name of lists location
    dd_Lookup = "StateFull" ' List of full names
    dd_Return = "StateCode" ' List of abbreviations/codes
    
'==============================================================

    '  Create a variable to temporarily hold the value
    '  returned by the XLOOKUP operation.
    Dim LookupResult As Variant

    '  Determine whether the changed cell/range includes C10.
    '  If C10 was not changed, immediately exit the procedure.
    If Intersect(Target, Range(dd_List)) Is Nothing Then Exit Sub

    '  If an error occurs after this point, jump to the
    '  CleanUp section to ensure Excel events are re-enabled.
    On Error GoTo CleanUp

    '  Temporarily disable Excel events so changing C10
    '  from VBA does not trigger Worksheet_Change again.
    Application.EnableEvents = False

    '  Perform the equivalent of the following Excel formula:
    '  =XLOOKUP(C10, StateFull, StateCode, "")
    
    '  Search StateFull for the value currently in C10
    '  and return the corresponding value from StateCode.
    '  If the state name is not found, return a blank value.
    LookupResult = Application.XLookup( _
                       Range(dd_List).Value, _
                       Worksheets(dd_Sheet).Range(dd_Lookup), _
                       Worksheets(dd_Sheet).Range(dd_Return), _
                       "")

    '  Replace the full state name currently in C10
    '  with the corresponding state abbreviation.
    Range(dd_List).Value = LookupResult

CleanUp:

    '  Re-enable Excel event processing.
    Application.EnableEvents = True

End Sub